package com.jsh.erp.utils;

/**
 *
 */
public enum ErpInfo {
    //通过构造传递参数
    OK(200, "成功","success"),
    BAD_REQUEST(400, "请求错误或参数错误","Request error or parameter error"),
    UNAUTHORIZED(401, "未认证用户","Unauthenticated User"),
    INVALID_VERIFY_CODE(461, "错误的验证码","Incorrect verification code"),
    ERROR(500, "服务内部错误","Service internal error"),
    FAILED(501, "获取数据失败","Failed to obtain data"),
    FOUND(502, "查找不到数据","No data found"),
    WARING_MSG(201, "提醒信息","tooltip"),
    REDIRECT(301, "session失效，重定向","The session is invalid and redirected. Procedure"),
    FORWARD_REDIRECT(302, "转发请求session失效","The session of forwarding request is invalid. Procedure"),
    FORWARD_FAILED(303, "转发请求失败!" ,"Forwarding request failed!"),
    UPDATE_STOCK_FAILED(500, "管理员不能操作，请切换租户账号!" ,"The administrator cannot perform this operation. Please switch the tenant account"),
    TEST_USER(-1, "演示用户禁止操作","Demonstration user prohibited operation");

    public final int code;
    public final String name;
    public final String lanCodeName;

    public int getCode() {
        return code;
    }

    public String getName() {
        return name;
    }

    public String getLanCodeName() {
        return lanCodeName;
    }

    /**
     * 定义枚举构造函数
     */
    ErpInfo(int code, String name,String lanCodeName) {
        this.code = code;
        this.name = name;
        this.lanCodeName = lanCodeName;
    }
}
